

import { createSSRApp } from "vue";
import App from "./App.vue";
import uviewPlus from 'uview-plus'
import { createPinia } from 'pinia'
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
import "@/styles/base.scss";
import "uview-plus/index.scss";

export function createApp() {
    const app = createSSRApp(App);
    app.use(createPinia().use(piniaPluginPersistedstate))
    app.use(uviewPlus)
    // uni.$u.config.unit = 'rpx'
    app.config.globalProperties.$imgUrl = import.meta.env.VITE_APP_IMAGE_URL
    app.config.globalProperties.$imgBase = import.meta.env.VITE_APP_IMG_URL
    return {
        app,
    };
}
